<%@ include file="/common/taglibs.jsp"%>

<title><fmt:message key="companyDetail.title"/></title>
<content tag="heading"><fmt:message key="companyDetail.heading"/></content>

<html:form action="saveCompany" method="post" styleId="companyForm" onsubmit="return validateCompanyForm(this)">
<ul>

<html:hidden property="id"/>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.companyId"/>
        <html:errors property="companyId"/>
        <html:text property="companyId" styleId="companyId" styleClass="text medium"/>
    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.companyName"/>
        <html:errors property="companyName"/>
        <html:text property="companyName" styleId="companyName" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.description"/>
        <html:errors property="description"/>
        <html:text property="description" styleId="description" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.companyEngName"/>
        <html:errors property="companyEngName"/>
        <html:text property="companyEngName" styleId="companyEngName" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.abbreviation"/>
        <html:errors property="abbreviation"/>
        <html:text property="abbreviation" styleId="abbreviation" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.address"/>
        <html:errors property="address"/>
        <html:text property="address" styleId="address" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.engAddress"/>
        <html:errors property="engAddress"/>
        <html:text property="engAddress" styleId="engAddress" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.email"/>
        <html:errors property="email"/>
        <html:text property="email" styleId="email" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.companyNo"/>
        <html:errors property="companyNo"/>
        <html:text property="companyNo" styleId="companyNo" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.tel"/>
        <html:errors property="tel"/>
        <html:text property="tel" styleId="tel" styleClass="text medium"/>

    </li>

    <li>
        <generalsetting:label styleClass="desc" key="companyForm.fax"/>
        <html:errors property="fax"/>
        <html:text property="fax" styleId="fax" styleClass="text medium"/>

    </li>

    <li class="buttonBar bottom">
        <html:submit styleClass="button" property="method.save" onclick="bCancel=false">
            <fmt:message key="button.save"/>
        </html:submit>

        <html:submit styleClass="button" property="method.delete" onclick="bCancel=true; return confirmDelete('Company')">
            <fmt:message key="button.delete"/>
        </html:submit>

        <html:cancel styleClass="button" onclick="bCancel=true">
            <fmt:message key="button.cancel"/>
        </html:cancel>
    </li>
</ul>
</html:form>

<script type="text/javascript">
    Form.focusFirstElement($("companyForm"));
</script>

<html:javascript formName="companyForm" cdata="false" dynamicJavascript="true" staticJavascript="false"/>
<script type="text/javascript" src="<html:rewrite page="/scripts/validator.jsp"/>"></script>
